/**
 * HW12
 *
 * brief description of the program
 *
 * This program is released to public domain according to
 * author's wish, you can view full license at
 * http://tomatoeskit.org/upload/PublicDomainLicense.txt
 *
 * @author Fangning CHENG (Alpha.L Cheng) <chengf@purdue.edu>
 *
 * @lab section number 
 *
 * @date Sep 16, 2013
 *
 */

public class Matrix {
    private int[][] _matrix;
    public Matrix(int[][] matrix)
    {
        _matrix = matrix;
    }
    
    public int sum()
    {
        int ret = 0;
        for (int[] row : _matrix) {
            for (int element : row) {
                ret += element;
            }
        }
        return ret;
    }
}
